<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>

    <ul id="root">
        <li>1</li>
        <li>2</li>
        <li>3</li>
    </ul>

    <script>
        // 关于NodeList和HTMLConnection的思考
        let ul1 = document.querySelectorAll('ul')[0];
        let list2 = ul1.querySelectorAll('li')[0];
        let ul = document.getElementsByTagName('ul')[0];
        let list = ul.getElementsByTagName('li')[0];
        console.log(list === list2)
    </script>
</body>

</html>